﻿#ifndef BTFORM_H
#define BTFORM_H

#include <QWidget>
#include <QString>
#include <QDebug>
#include <QPropertyAnimation>


namespace Ui {
class BtForm;
}

class BtForm : public QWidget
{
    Q_OBJECT

public:
    explicit BtForm(QWidget *parent = 0);
    ~BtForm();

    void setIconAndText(const QString& icon,const QString& context,int pageId);

    int getPageId();

    void clearBackground();

    void showAnimal(bool isShow);
protected:
    void mousePressEvent(QMouseEvent* event);

signals:
    void btClick(int id);

private:
    Ui::BtForm *ui;
    int pageId;

    QPropertyAnimation* line1Animal;
    QPropertyAnimation* line2Animal;
    QPropertyAnimation* line3Animal;
    QPropertyAnimation* line4Animal;
};

#endif // BTFORM_H
